{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {},
   "outputs": [],
   "source": [
    "#r \"nuget:AngouriMath.Interactive, *-*\" // installing the Interactive package\n",
    "Interactive.magic() // run this code to register all interacting stuff"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {},
   "outputs": [],
   "source": [
    "open Functions\n",
    "open Core\n",
    "open Operators"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "\r\n",
       "            <script src='https://polyfill.io/v3/polyfill.min.js?features=es6'></script>\r\n",
       "            <script id='MathJax-script' async src='https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js'></script>\r\n",
       "            \\[{x}^{2}+\\sin\\left(\\sqrt{x+\\frac{1}{2}}\\right)+\\int \\left[\\sqrt{x+\\frac{d\\left[\\sin\\left(y\\right)\\right]}{dy}}\\right] dx\\]\r\n",
       "            "
      ]
     },
     "execution_count": 8,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "parse \"x2 + sin(sqrt(x + 1/2)) + integral(sqrt(x + derivative(sin(y), y)), x)\""
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "\r\n",
       "            <script src='https://polyfill.io/v3/polyfill.min.js?features=es6'></script>\r\n",
       "            <script id='MathJax-script' async src='https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js'></script>\r\n",
       "            \\[\\frac{1}{2}\\times \\frac{1}{\\sqrt{\\sin\\left(x\\right)+\\frac{1}{x+\\epsilon}}}\\times \\left(\\cos\\left(x\\right)+\\frac{-1}{{\\left(x+\\epsilon\\right)}^{2}}\\right)+{e}^{3\\times {x}^{2}}\\times 2\\times x\\times 3\\]\r\n",
       "            "
      ]
     },
     "execution_count": 9,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "differentiate \"x\" \"sqrt(sin(x) + 1 / (x + epsilon)) + e^(3x2)\""
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "\r\n",
       "            <script src='https://polyfill.io/v3/polyfill.min.js?features=es6'></script>\r\n",
       "            <script id='MathJax-script' async src='https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js'></script>\r\n",
       "            \\[\\left\\{ 3 \\right\\}\\]\r\n",
       "            "
      ]
     },
     "execution_count": 11,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "solve \"x\" \"x > 0 and x ^ 2 = 9\""
   ]
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": ".NET (F#)",
   "language": "F#",
   "name": ".net-fsharp"
  },
  "language_info": {
   "file_extension": ".fs",
   "mimetype": "text/x-fsharp",
   "name": "C#",
   "pygments_lexer": "fsharp",
   "version": "4.5"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
